package day3;

public class MethodTest {
	public static void main(String[] args) {
		int[] counts = {23, 56, 8, 99, 2};
		int max= max(counts);
		System.out.println(max);
		
	}
	
	public static int max(int[] array) {
		int max = array[0];
		for (int i = 0; i < array.length; i++) {
			if(max < array[i]) {
				max = array[i];
			}
		}
		return max;
	}
		

}
